<?
/***
*    This file is part of Marketorama.
*
*    Marketorama is free software: you can redistribute it and/or modify
*    it under the terms of the GNU General Public License as published by
*    the Free Software Foundation, either version 3 of the License, or
*    (at your option) any later version.
*
*    Marketorama is distributed in the hope that it will be useful,
*    but WITHOUT ANY WARRANTY; without even the implied warranty of
*    MERCHANTABILITY or FITNESS FOR A PARTICULAR *PURPOSE.  See the
*    GNU General Public License for more details.
*
*    You should have received a copy of the GNU General Public License
*    along with Marketorama.  If not, see <http://www.gnu.org/licenses/>.
***/
class Users extends Controller 
{
    function index()
	{
		
	}
	
	function view_profile($username)
	{
			$this->load->model('usersmodel');
			$data=$this->usersmodel->getUserProfile($username);
			$header_data['title']=($data==null?'Error accessing profile':$data->UserName);
			$header_data['current']=($data==null?'Error accessing profile':$data->UserName);
			$this->load->view('template/header', $header_data);
			$this->load->view('user_view', $data);
			$this->load->view('template/footer');
	}
}
?>